﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using StructureMap.Configuration.DSL;
using Universum.Model.Services.QuestionIt;
using Universum.Model.Services;
using Universum.Model.Services.Indexing;

namespace Universum.Infrastructure.Configuration
{
	public class QuestionItRegistry : Registry
	{
		public QuestionItRegistry()
		{
			ForRequestedType<IQuestionService>()
				.TheDefaultIsConcreteType<QuestionServiceImpl>();
			ForRequestedType<IDurationService>()
				.TheDefaultIsConcreteType<DurationServiceImpl>();
			ForRequestedType<IQuestionIndexingService>()
				.TheDefaultIsConcreteType<QuestionIndexingServiceImpl>().CacheBy(StructureMap.Attributes.InstanceScope.PerRequest);
		}
	}
}
